package com.talkology.pilot.manager.controller;

import com.talkology.pilot.manager.model.MailInfo;
import com.talkology.pilot.manager.service.IEmailMgtService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping(value = "/mail")
public class EmailMgtController {
    @Autowired
    private IEmailMgtService service;

    @RequestMapping(value = "/sending", method= RequestMethod.POST)
    @ResponseBody
    public void sendMails(@RequestBody MailInfo mailInfo) {
        service.sendEmail(mailInfo);
    }

}
